home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 13537 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.2 KB  |  36 lines

  1. Path: castle.nando.net!news
  2. From: Caius Martius <caius@nando.net>
  3. Newsgroups: comp.lang.c++
  4. Subject: Re: How to clear screen?
  5. Date: Mon, 25 Mar 1996 17:16:35 -0800
  6. Organization: Carolantic Realty, Inc.
  7. Message-ID: <31574573.44E4@nando.net>
  8. References: <4gmalh$csq@cloner3.netcom.com> <Pine.A32.3.91.960228152731.19882A-100000@pegasus.acs.ttu.edu> <315527F6.3880@ljusdal.se>
  9. NNTP-Posting-Host: grail2115.nando.net
  10. Mime-Version: 1.0
  11. Content-Type: text/plain; charset=iso-8859-1
  12. Content-Transfer-Encoding: 8bit
  13. X-Mailer: Mozilla 2.0 (Win95; I; 16bit)
  14.  
  15. Marcsu wrote:
  16. > akefay oscarway ayermay einerway wrote:
  17. > > > Is there a function to clear a text screen?
  18. > > #include <conio.h> // for clear screen function
  19. > > clrscr();
  20. > > this is for dos ...the header file is different for unix, and I do
  21. > > not know what it is....you can probably do a man on the function, or
  22. > > maybe not.
  23. > There┤s someone out there who knows what, the clear screen , function
  24. > etc. (header file), is called under UNIX(Linux), please post!!!
  25. > /marcsu
  26. > marcus.berggren@ljusdal.se
  27.  
  28. Just put this in a function...  Works great on a unix system.
  29.  
  30. cout << '\033' << "[;H" << '\033' <<"[2J" << flush;
  31.  
  32. -Caius
  33.